<!DOCTYPE html>
<html>
<head>
	<title>工作流图</title>
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
	<link rel="stylesheet" href="__PUBLIC__/Admin/css/min.css" />
	<link rel="stylesheet" href="__PUBLIC__/Admin/content/style.css" />

	<!-- jQuery AND jQueryUI -->
	<script type="text/javascript" src="__PUBLIC__/Admin/js/libs/jquery/1.6/jquery.min.js"></script>
	<script type="text/javascript" src="__PUBLIC__/Admin/js/libs/jqueryui/1.8.13/jquery-ui.min.js"></script>
	<script type="text/javascript" src="__PUBLIC__/Admin/js/min.js"></script>
	<script type="text/javascript" src="__PUBLIC__/Admin/content/main.js"></script>
</head>
<body>
<style>
table{
	/* border:5px red solid; */
	margin:0 auto;
	width:70%;
}
tr{
	
}
td{
	height:100px;
	width:150px;
	padding:20px;
}
td div{
	height:100px;
	width:150px;
	padding:10px;
	font-size:12px;
	line-height:100px;
}
.status0{
	background-color:green;
	border-radius:50%;	
	border:1px gray solid;
}
.status1{
	background-color:#6495ED;
	border-radius:0%;	
	border:1px gray solid;	
}
.status2{
	background-color:#6495ED;
	border-radius:0%;	
	border:1px gray solid;	
}
.status3{
	background-color:#6495ED;
	border-radius:50%;	
	border:1px gray solid;	
}
</style>
   <div class="title" style="text-align:center">
	<?php
		$id = I('get.id');
			if($id){
		?>
		{$object['name']}
		<a target="_blank" href="{:U('WorkflowNode/editUI')}" >新建节点</a>
		<a target="_blank" href="{:U('WorkflowNode/index')}?workflowid={$id}" >查询节点</a>
	<?php
		}
		?>
	</div>
	<?php
		$id = I('get.id');
			if($id){
				echo "<input type='hidden' name='id' value='".$id."'/>";
			}
		?>
	<table border="1">
		<volist name='nodelist' id='tr'>
			<?php 
				$j = 0;
			?>
			<tr>
				<td>
					<?php
						if($tr[type]==0){
									echo '<div class=status0>';
								}else if($tr[type]==1){
									echo '<div class=status1>';
								}else if($tr[type]==2){
									echo '<div class=status2>';
								}else if($tr[type]==3){
									echo '<div class=status3>';
								}
							?>
						<a href="#" title="
								节点id:{$tr.id}<br>
								节点名称:{$tr.name}<br>
								节点类型:{$tr.type}<br>
								操作者类型:{$tr.handlertype}<br>
								操作者对象:{$tr.handlerobject}<br>">
								当前节点名称:{$tr.name}<br>
						</a>
					</div>
				</td>
				<volist name='nodelist' id='td'>
					<?php
						if($tr[id]==$td[prevnodeid]){
						?>
						<td>
							<?php
								if($td[type]==0){
									echo '<div class=status0>';
								}else if($td[type]==1){
									echo '<div class=status1>';
								}else if($td[type]==2){
									echo '<div class=status2>';
								}else if($td[type]==3){
									echo '<div class=status3>';
								}
							?>
								<a href="#" title="
										节点id:{$td.id}<br>
										节点名称:{$td.name}<br>
										节点类型:{$td.type}<br>
										操作者类型:{$td.handlertype}<br>
										操作者对象:{$td.handlerobject}<br>">
										节点名称:{$td.name}<br>
								</a>
							</div>
						</td>
					<?php
						}else{
							$j=$j+1;
						}
					?>
				</volist>
				<?php 
					for($q=1;$q<$j;$q++){
				?>
					<td>
						<div>
							-
						</div>
					</td>
				<?php 
					}
				?>
			</tr>
		</volist>
	<table/>
</body>
</html>